<?php

namespace App\Http\Controllers;

use Illuminate\Http\Request;
use Illuminate\Support\Facades\Validator;

class FeedbackController extends Controller
{
    // 意见反馈
    public function feedback(Request $request)
    {
        $validator = Validator::make($request->all(), [
            'content'   => 'required|string|max:500',
            'contact'   => 'sometimes|string',
        ]);

        if ($validator->fails()) {
            return $this->validationError($validator->errors());
        }

        return $this->success([], '提交成功');
    }


}
